package com.mp.approvalreq.entity.dto;

import java.util.Objects;

/**
 * Created by liuqi on 2018/6/28.
 */
public class TemplateRangeDTO {
	
	private Integer templateId;
	private Integer templateType;
	/**
	 *  departmentIds = 0时,表示全公司
	 */
	private String departmentIds;
	
	private String contactIdRange;
	
	private String companyInfoIdRange;
	
	public TemplateRangeDTO() {
	}
	
	public Integer getTemplateId() {
		return templateId;
	}
	
	public void setTemplateId(Integer templateId) {
		this.templateId = templateId;
	}
	
	public Integer getTemplateType() {
		return templateType;
	}
	
	public void setTemplateType(Integer templateType) {
		this.templateType = templateType;
	}
	
	public String getDepartmentIds() {
		return departmentIds;
	}
	
	public void setDepartmentIds(String departmentIds) {
		this.departmentIds = departmentIds;
	}
	
	public String getContactIdRange() {
		return contactIdRange;
	}
	
	public void setContactIdRange(String contactIdRange) {
		this.contactIdRange = contactIdRange;
	}
	
	public String getCompanyInfoIdRange() {
		return companyInfoIdRange;
	}
	
	public void setCompanyInfoIdRange(String companyInfoIdRange) {
		this.companyInfoIdRange = companyInfoIdRange;
	}
	
	@Override
	public boolean equals(Object o) {
		if (this == o) {
			return true;
		}
		if (o == null || getClass() != o.getClass()) {
			return false;
		}
		TemplateRangeDTO that = (TemplateRangeDTO) o;
		return Objects.equals(templateId, that.templateId) &&
				Objects.equals(templateType, that.templateType) &&
				Objects.equals(departmentIds, that.departmentIds) &&
				Objects.equals(contactIdRange, that.contactIdRange) &&
				Objects.equals(companyInfoIdRange, that.companyInfoIdRange);
	}
	
	@Override
	public int hashCode() {
		return Objects.hash(templateId, templateType, departmentIds, contactIdRange, companyInfoIdRange);
	}
	
	@Override
	public String toString() {
		return "TemplateRangeDTO{" +
				"templateId=" + templateId +
				", templateType=" + templateType +
				", departmentIds='" + departmentIds + '\'' +
				", contactIdRange='" + contactIdRange + '\'' +
				", companyInfoIdRange='" + companyInfoIdRange + '\'' +
				'}';
	}
}
